﻿<!DOCTYPE html>
<html>
<!-- 安全经验分享库-在线预览PDF -->

<head>
    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1">
    <script src="/static/js/common.js"></script>
</head>

<body>
    <div id="app" class="popupW50" v-cloak>
        <iframe :src="myurl" style="height:450px;width:100%"></iframe>
    </div>
    <script type="text/javascript">
        var uploadText = "请选择上传文件";
        var app = new Vue({
            el: '#app',
            data: {
                //为了解决URL中包含两个?导致错误的问题，修改了PDFJS的View.js,参数由file改为file2
                myurl: '/static/pdfjs/web/viewer.html?file2=http://localhost:8080/api/file/DownLoad?id=',
                //父页传参
                id: '',
            },
            mounted: function () {
                this.id = getUrlParam("id");
                this.myurl = this.myurl + this.id;
            },

        });
    </script>
</body>

</html>